﻿<UserControl x:Class="NUnitResultsExplorer.Controls.TestCaseCountControl"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             mc:Ignorable="d" 
             d:DesignHeight="300" d:DesignWidth="300">
    <StackPanel>
        <ItemsControl ItemsSource="{Binding}">
            <ItemsControl.ItemsPanel>
                <ItemsPanelTemplate>
                    <StackPanel />
                </ItemsPanelTemplate>
            </ItemsControl.ItemsPanel>
            <ItemsControl.ItemTemplate>
                <DataTemplate>
                    <TextBlock>
                        <TextBlock Margin="0,2,0,2" MinWidth="100" Text="{Binding Key, Converter={StaticResource statusToStringConverter}}" />
                        <TextBlock Margin="0,2,0,2" MinWidth="50" TextAlignment="Right" Text="{Binding Value}" />
                    </TextBlock>
                </DataTemplate>
            </ItemsControl.ItemTemplate>
        </ItemsControl>
        <TextBlock>
            <TextBlock FontWeight="999" Margin="0,2,0,2" MinWidth="100" Text="Total Test Cases" />
            <TextBlock FontWeight="999" Margin="0,2,0,2" MinWidth="50" TextAlignment="Right" Text="{Binding Total}" />
        </TextBlock>
    </StackPanel>
</UserControl>
